cmake_minimum_required(VERSION 2.8)
PROJECT(main)
find_package(OpenCV 3.4.5)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c++11 -march=native")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -march=native")
include_directories(${OpenCV_INCLUDE_DIRS})
ADD_EXECUTABLE(main /home/sau/桌面/sentry8.0/main.cpp
					/home/sau/桌面/sentry8.0/header.h
                    /home/sau/桌面/sentry8.0/Aim/AngleSolver.cpp
                    /home/sau/桌面/sentry8.0/Aim/AngleSolver.hpp  
                    /home/sau/桌面/sentry8.0/Aim/ArmorDetector.cpp
                    /home/sau/桌面/sentry8.0/Aim/ArmorDetector.hpp 
                    /home/sau/桌面/sentry8.0/Aim/separate.h
                    /home/sau/桌面/sentry8.0/Aim/Settings.hpp
					/home/sau/桌面/sentry8.0/SerialPort/serialport.h       
					/home/sau/桌面/sentry8.0/SerialPort/serialport.cpp      
					/home/sau/桌面/sentry8.0/SerialPort/CRC_Check.cpp      
                    /home/sau/桌面/sentry8.0/SerialPort/CRC_Check.h         
                    /home/sau/桌面/sentry8.0/Camera/RMVideoCapture.hpp     
                    /home/sau/桌面/sentry8.0/Camera/RMVideoCapture.cpp     
)
target_link_libraries(main ${OpenCV_LIBS})
find_package(Threads)
target_link_libraries(main ${CMAKE_THREAD_LIBS_INIT})
find_package(X11 REQUIRED)
include_directories(${X11_INLUCDE_DIR})
target_link_libraries(main ${X11_LIBRARIES})
